function Plot( tEvent )
	%
	if( numel(tEvent.aafRawData) == 0 )
		%
		fprintf('discarded plotting an occupancy event because having no information on it\n');
		return;
		%
	end;%
	%
	tLabels = PeopleCounters.LoadRawEventsLabels();
	%
	% rewrite the times in an opportune manner
	aiTimes					= tEvent.aafRawData(1, 2):1:tEvent.aafRawData(end, 2);
	aiPlotTimes				= aiTimes - min( aiTimes );
	%
	% to form binary signals we consider each row data event so that we
	% have 0 before each opening, 1 after the corresponding opening, and
	% then 0 after the corresponding closing
	afOriginalDoorSignal	= zeros(numel(aiPlotTimes), 1); 
	afOriginalLaser1Signal	= zeros(numel(aiPlotTimes), 1); 
	afOriginalLaser2Signal	= zeros(numel(aiPlotTimes), 1);
	%
	% now scan the list of each raw event, and change the remaining of the
	% signal opportunely
	for iRawEvent = 1:numel( tEvent.aafRawData(:, 1) )
		%
		iCurrentTime = tEvent.aafRawData(iRawEvent, 2) - aiTimes(1) + 1;
		%
		switch tEvent.aafRawData(iRawEvent, 1);
			%
			case tLabels.DOOR_OPEN
				afOriginalDoorSignal(iCurrentTime:end)	= 1;
			%	
			case tLabels.DOOR_CLOSE
				afOriginalDoorSignal(iCurrentTime:end)	= 0;
			%
			case tLabels.LASER_1_OPEN
				afOriginalLaser1Signal(iCurrentTime:end)		= 1;
			%
			case tLabels.LASER_1_CLOSE
				afOriginalLaser1Signal(iCurrentTime:end)		= 0;
			%
			case tLabels.LASER_2_OPEN
				afOriginalLaser2Signal(iCurrentTime:end)		= 1;
			%
			case tLabels.LASER_2_CLOSE
				afOriginalLaser2Signal(iCurrentTime:end)		= 0;
			%
			case 0
				% do nothing; it means that the signal ID has been set to
				% zero to overwrite some duplicate key -- check
				% RemoveRedundantData()
			%
			otherwise
				error('wtf')
			%	
		end;% switch
		%
	end;% for
	%
	%
	%
	afMergedDoorSignal		= zeros(numel(aiPlotTimes), 1); 
	afMergedLaser1Signal	= zeros(numel(aiPlotTimes), 1); 
	afMergedLaser2Signal	= zeros(numel(aiPlotTimes), 1);
	%
	for iTransition = 1:size( tEvent.aaiDoorOpeningClosingTransitions, 1 );
		%
		iStartingIndex	= find( aiPlotTimes == tEvent.aaiDoorOpeningClosingTransitions(iTransition, 1) - aiTimes(1), 1, 'first' );
		iEndingIndex	= find( aiPlotTimes == tEvent.aaiDoorOpeningClosingTransitions(iTransition, 2) - aiTimes(1), 1, 'last' );
		%
		afMergedDoorSignal( iStartingIndex:iEndingIndex ) = ...
			ones( size(afMergedDoorSignal( iStartingIndex:iEndingIndex )) );
		%
	end;%
	%
	for iTransition = 1:size( tEvent.aaiLaser1OpeningClosingTransitions, 1 );
		%
		iStartingIndex	= find( aiPlotTimes == tEvent.aaiLaser1OpeningClosingTransitions(iTransition, 1) - aiTimes(1), 1, 'first' );
		iEndingIndex	= find( aiPlotTimes == tEvent.aaiLaser1OpeningClosingTransitions(iTransition, 2) - aiTimes(1), 1, 'last' );
		%
		afMergedLaser1Signal( iStartingIndex:iEndingIndex ) = ...
			ones( size(afMergedLaser1Signal( iStartingIndex:iEndingIndex )) );
		%
	end;%
	%
	for iTransition = 1:size( tEvent.aaiLaser2OpeningClosingTransitions, 1 );
		%
		iStartingIndex	= find( aiPlotTimes == tEvent.aaiLaser2OpeningClosingTransitions(iTransition, 1) - aiTimes(1), 1, 'first' );
		iEndingIndex	= find( aiPlotTimes == tEvent.aaiLaser2OpeningClosingTransitions(iTransition, 2) - aiTimes(1), 1, 'last' );
		%
		afMergedLaser2Signal( iStartingIndex:iEndingIndex ) = ...
			ones( size(afMergedLaser2Signal( iStartingIndex:iEndingIndex )) );
		%
	end;%
	%
	%
	% ----------------------------------------------------------------
	% Plots
	figure( tEvent.iLabel )
	suptitle(sprintf('Measured Class: %s,                   Estimated Class: %s', tEvent.strMeasuredClass, tEvent.strEstimatedClass));
	%
	subplot(3,1,1)
	hold on;
	area(aiPlotTimes, afOriginalDoorSignal, 'EdgeColor', [.5 .5 .5], 'FaceColor', [.5 .5 .5], 'LineWidth', 0.1)
	plot(aiPlotTimes, afMergedDoorSignal, 'k', 'LineWidth', 2.5)
	hold off;
	title('door');
	ylim([0 1.5]);
	xlabel('ms')
	%
	subplot(3,1,2)
	hold on;
	area(aiPlotTimes, afOriginalLaser1Signal, 'EdgeColor', [.5 .5 .5], 'FaceColor', [.5 .5 .5], 'LineWidth', 0.1)
	plot(aiPlotTimes, afMergedLaser1Signal, 'k', 'LineWidth', 2.5)
	hold off;
	title('laser 1');
	ylim([0 1.5]);
	xlabel('ms')
	%
	subplot(3,1,3)
	hold on;
	area(aiPlotTimes, afOriginalLaser2Signal, 'EdgeColor', [.5 .5 .5], 'FaceColor', [.5 .5 .5], 'LineWidth', 0.1)
	plot(aiPlotTimes, afMergedLaser2Signal, 'k', 'LineWidth', 2.5)
	hold off;
	title('laser 2');
	ylim([0 1.5]);
	xlabel('ms')
	%
end % function

